package com.yy.tech.inte;

import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.client.RestTemplate;

/**
 * technical-identification$
 *
 * @author YY
 * @version 1.0.0
 * @date $ $
 * @description: TODO
 */
@Configuration
@ComponentScan
public class InteConfiguration {

    @Bean
    @ConditionalOnMissingBean
    public RestTemplate restTemplate(){
        return new RestTemplate();
    }

    @Bean("inteRestTemplate")
    @ConditionalOnMissingBean(name = "inteRestTemplate")
    public RestTemplate inteRestTemplate(){
        return new RestTemplate();
    }
}
